package com.fqgj.sentry.controller.pc.request;

import com.fqgj.sentry.common.exception.BizException;
import com.fqgj.sentry.common.exception.enums.ErrorCodeEnums;
import com.fqgj.sentry.common.request.ParamsObject;

/**
 * Created by ykpbean kangping.ying@yuntu-inc.com
 *
 * @description
 * @create 2017-07-29 上午9:27
 */


public class ExecutorSwitchVo extends ParamsObject {
    private  Long executorId;
    private  Boolean isOpen;
    @Override
    public void validate() {
        if (isOpen==null || executorId ==null){
            throw  new BizException(ErrorCodeEnums.param_valid_error);
        }
    }

    public Long getExecutorId() {
        return executorId;
    }

    public ExecutorSwitchVo setExecutorId(Long executorId) {
        this.executorId = executorId;
        return this;
    }

    public Boolean getOpen() {
        return isOpen;
    }

    public ExecutorSwitchVo setOpen(Boolean open) {
        isOpen = open;
        return this;
    }
}
